import { createSlice } from "@reduxjs/toolkit"

const messageSlice = createSlice({
    name: "message",
    initialState: {
        message: "Hello World",
    },
    reducers: {
        changeMessageAction(state, { payload }) {
            state.message = payload
        },
    },
})

export const { changeMessageAction } = messageSlice.actions 

export default messageSlice.reducer
